home *** CD-ROM | disk | FTP | other *** search
-
-
-
- iiiillllIIIInnnnddddeeeexxxxaaaabbbblllleeeeLLLLiiiisssstttt((((3333)))) IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll
-
-
-
- NNNNAAAAMMMMEEEE
- iiiillllIIIInnnnddddeeeexxxxaaaabbbblllleeeeLLLLiiiisssstttt - Indexable linked list
-
- IIIINNNNHHHHEEEERRRRIIIITTTTSSSS FFFFRRRROOOOMMMM
- This class has only private inheritances from base classes.
-
- HHHHEEEEAAAADDDDEEEERRRR FFFFIIIILLLLEEEE
- #include <il/ilIndexableList.h>
-
- CCCCLLLLAAAASSSSSSSS DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
- ilIndexableList is privately derived from the ilList class. ilIndexable
- list provides a lightweight, fast, doubly-linked list that can be indexed
- by an integer. The class maintains a cache of the last accessed
- position, and uses that to provide fast positioning within the list. The
- index is constrained from zero (the head of the list) to the list length
- minus one.
-
- UUUUssssiiiinnnngggg iiiillllIIIInnnnddddeeeexxxxaaaabbbblllleeeeLLLLiiiisssstttt
- To make a list of integers, for example, define a derivation of
- ilLinkItem to hold the integer:
-
- struct intItem : public ilLinkItem {
- int i;
- };
-
- Next, build a list of these integers:
-
- ilIndexableList list;
- for (int i = 0; i < 10; i++) {
- intItem* item = new intItem;
- item->i = i;
- list.append(item);
- }
-
- In the example above, the _a_p_p_e_n_d function was used to place the items on
- the list. Once the list is created, it can be manipulated.
-
- CCCCLLLLAAAASSSSSSSS MMMMEEEEMMMMBBBBEEEERRRR FFFFUUUUNNNNCCCCTTTTIIIIOOOONNNN SSSSUUUUMMMMMMMMAAAARRRRYYYY
- CCCCoooonnnnssssttttrrrruuuuccccttttoooorrrr
-
- ilIndexableList()
-
-
-
-
-
-
-
-
-
-
-
-
- PPPPaaaaggggeeee 1111
-
-
-
-
-
-
- iiiillllIIIInnnnddddeeeexxxxaaaabbbblllleeeeLLLLiiiisssstttt((((3333)))) IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll
-
-
-
- EEEEddddiiiittttiiiinnnngggg
-
- void append(ilLinkItem* item)
- void appendAt(int index, ilLinkItem* item)
- void insert(ilLinkItem* item)
- void insertAt(int index, ilLinkItem* item)
- void unlink(ilLinkItem* item)
- void unlinkAt(int index)
-
-
- QQQQuuuueeeerrrryyyy
-
- int length()
- ilLinkItem* head()
- ilLinkItem* tail()
- ilLinkItem* findLink(int index)
- ilLinkItem* operator[](int index)
- ilLinkItem* getNext(const ilLinkItem* item)
- ilLinkItem* getPrev(const ilLinkItem* item)
- int isValid()
-
-
- FFFFUUUUNNNNCCCCTTTTIIIIOOOONNNN DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNNSSSS
- iiiillllIIIInnnnddddeeeexxxxaaaabbbblllleeeeLLLLiiiisssstttt(((())))
-
- ilIndexableList()
-
-
- Creates an ilIndexableList of length zero (that is, empty list).
-
- aaaappppppppeeeennnndddd(((())))
-
- void append(ilLinkItem* item)
-
-
- Appends _i_t_e_m to the end of the list.
-
- aaaappppppppeeeennnnddddAAAAtttt(((())))
-
- void appendAt(int index, ilLinkItem* item)
-
-
- Places _i_t_e_m after _i_n_d_e_x in the list. If _i_n_d_e_x is out of range, then
- the _i_t_e_m is apppended to the end of the list.
-
- hhhheeeeaaaadddd(((())))
-
- ilLinkItem* head()
-
-
-
-
-
-
-
- PPPPaaaaggggeeee 2222
-
-
-
-
-
-
- iiiillllIIIInnnnddddeeeexxxxaaaabbbblllleeeeLLLLiiiisssstttt((((3333)))) IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll
-
-
-
- Returns the item at the head of the list or NULL if the list is
- empty.
-
- ffffiiiinnnnddddLLLLiiiinnnnkkkk(((())))
-
- ilLinkItem* findLink(int index)
-
-
- Returns the item at _i_n_d_e_x.
-
- ggggeeeettttNNNNeeeexxxxtttt(((())))
-
- ilLinkItem* getNext(const ilLinkItem* item)
-
-
- Returns the list element following _i_t_e_m.
-
- ggggeeeettttPPPPrrrreeeevvvv(((())))
-
- ilLinkItem* getPrev(const ilLinkItem* item)
-
-
- Returns the list element preceding _i_t_e_m.
-
- iiiinnnnsssseeeerrrrtttt(((())))
-
- void insert(ilLinkItem* item)
-
-
- Inserts _i_t_e_m at the front of the list.
-
- iiiinnnnsssseeeerrrrttttAAAAtttt(((())))
-
- void insertAt(int index, ilLinkItem* item)
-
-
- Places _i_t_e_m before _i_n_d_e_x in the list. If _i_n_d_e_x is out of range,
- then the _i_t_e_m is appended to the end of the list.
-
- iiiissssVVVVaaaalllliiiidddd(((())))
-
- int isValid()
-
-
- Returns TRUE if 'this' linked list is a valid list without any
- irregularities and a FALSE otherwise. A list is valid if each node
- or item points correctly to the next and previous item on the list.
-
- lllleeeennnnggggtttthhhh(((())))
-
-
-
-
-
-
- PPPPaaaaggggeeee 3333
-
-
-
-
-
-
- iiiillllIIIInnnnddddeeeexxxxaaaabbbblllleeeeLLLLiiiisssstttt((((3333)))) IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll
-
-
-
- int length()
-
-
- Returns the number of items in the list. If the list is empty, the
- returned value is 0.
-
- ooooppppeeeerrrraaaattttoooorrrr[[[[]]]]
-
- ilLinkItem* operator[](int index)
-
-
- Returns the item at _i_n_d_e_x. Same as _f_i_n_d_L_i_n_k.
-
- ttttaaaaiiiillll(((())))
-
- ilLinkItem* tail()
-
-
- Returns the item at the tail of the list or NULL if the list is
- empty.
-
- uuuunnnnlllliiiinnnnkkkk(((())))
-
- void unlink(ilLinkItem* item)
-
-
- Unlinks the _i_t_e_m from the list. If _i_t_e_m is not on the list, the
- result is undefined.
-
- uuuunnnnlllliiiinnnnkkkkAAAAtttt(((())))
-
- void unlinkAt(int index)
-
-
- Unlinks the item at _i_n_d_e_x.
-
- SSSSEEEEEEEE AAAALLLLSSSSOOOO
- ilIndexableStack
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- PPPPaaaaggggeeee 4444
-
-
-
-